*** Settings ***
Documentation    TC06-Update Lane AIR
Resource    ../../Keywords/Common_Head.robot
Resource    ../../Keywords/Common/Common_kw.robot
Metadata    Author     Terence
Force Tags    P3    BBB
Metadata    ID    14682


*** Variables ***
${G_TENDERID}    AUTO 8449
${TenderTitle}    Regression Test by Wendy001

*** Test Cases ***
TC06-Update Lane AIR
    Step 1 User Goes To Basic Data Management Tender List
    Step 2 User Goes To Pricing Collaboration Pricing Project
    Step 3 Input Following Attributes
    Step 4 User Selects Row That Project Name Is 20240815 AIR
    Step 5 Click On Copy Data
    Step 6 Input Tender ID With Value 2024000001 Click On Search
    Step 7 Select This Entry Click On Copy Data Button And Yes In
    Step 8 Select Current Project In Pricing Project Click On
    Step 9 Click Skip Button In Step4 and Yes In The Pop up
    Step 10 User Clicks Next Round Management Button
    Step 11 User Clicks Update Lane Button
    Step 12 Select Update Existing Lanes
    Step 13 User Clicks Download Button
    Step 14 User Opens The Downloaded File
    Step 15 User Modifies Some Pricing Data From The Download File
    Step 16 User Modifies Some Pricing Data From The Download File 15
    Step 17 User Modifies Some Pricing Data From The Download File 16
    Step 18 User Modifies Some Pricing Data From The Download File 17
    Step 19 User Modifies Some Pricing Data From The Download File 18
    Step 20 Click On Download Button Check The Downloaded File
    Step 21 In Pricing Project Page User Selects TenderID Contains
    Step 22 Select This Project 20240815 AIR Regression Click On
    Step 23 User Goes To Basic Data Management Tender List 22

*** Keywords ***
Step ${step} User Goes To Basic Data Management Tender List
    #************************Step 1******************************
    #  Do:
    #      User goes to Basic Data Management Tender List
    #      Click Create button
    #      Input with following attributes
    #      Tender ID some numbers such as 202408151435001 you can
    #     input with current datetime and some random number to
    #     avoid duplicate validation
    #      Tender Title some value such as Regression Test by
    #     Wendy001
    #      Customer 815 Miele
    #      Mode select all
    #      Level Global
    #      Click on Save button
    #  Expected:
    #      Created successfully with the message Tender has been
    #     added
    #************************************************************
    Login Space
    ${G_TENDERID}    Generate Tender ID
    ${TenderTitle}   Set Variable    Regression Test by Wendy001
    Set Suite Variable     ${G_TENDERID}    ${G_TENDERID}
    Set Suite Variable     ${TenderTitle}    ${TenderTitle}
    Create Tender    ${G_TENDERID}    ${TenderTitle}    815    true    true    true

Step ${step} User Goes To Pricing Collaboration Pricing Project
    #************************Step 2******************************
    #  Do:
    #      User goes to Pricing Collaboration Pricing Project
    #      User clicks Create Project button
    #  Expected:
    #      A New Project dialog should be opened successfully
    #************************************************************
    Log    Finish in next step

Step ${step} Input Following Attributes
    #************************Step 3******************************
    #  Do:
    #      Input following attributes
    #      Tender ID 20240815 Regression
    #      Mode Air
    #      Deadline to TM current date 10 day
    #      Rate Validity From current date
    #      Rate Validity To current date 100 day
    #      Deputies NATZHANG
    #      Description for regression
    #      Click on Save button
    #  Expected:
    #      A new project is created successfully
    #************************************************************
    ${DeadLine}    Get Current Date    UTC    +10days    result_format=%d/%m/%Y
    ${ValidFrom}    Get Current Date    UTC    result_format=%d/%m/%Y
    ${ValidTo}    Get Current Date    UTC    +30days    result_format=%d/%m/%Y
    ${PROJECT}    Copy Dictionary    ${PROJECT_PARAM}
    Set To Dictionary    ${PROJECT}    
    ...    TENDER_ID=${G_TENDERID}    TENDER_TITLE=${TenderTitle}    CUSTOEMR_NAME=Miele    CUSTOMER_LEVEL=Global
          ...   MODE=AIR    DEADLINE_TM_DATE=${DeadLine}    VALID_FROM=${ValidFrom}    VALID_TO=${ValidTo}    DEPUTY=NATZHANG
    Set Test Variable    ${PROJECT}    ${PROJECT}
    Create Project    ${PROJECT}

Step ${step} User Selects Row That Project Name Is 20240815 AIR
    #************************Step 4******************************
    #  Do:
    #      User selects row that project name is 20240815 AIR
    #     Regression
    #  Expected:
    #      The row can be selected successfully
    #************************************************************
    Search Project    ${PROJECT.TENDER_ID}

Step ${step} Click On Copy Data
    #************************Step 5******************************
    #  Do:
    #      Click on Copy Data
    #  Expected:
    #      A dialogue named Copy Target to Project 20240815 AIR
    #     Regression display
    #      Search Criteria
    #      Mode with value AIR uneditable
    #      Customer name with no value
    #      Tender ID with value ALL Editable
    #      Tender Lead with value ALL Editable
    #      RFQ Launch Date with value DD MM YYYY Editable
    #      Search button
    #      Result list has no entry present
    #      Copy Data button is disable now
    #************************************************************
    # Click    ${Project_toolbar_CopyData}
    # Wait For Elements State    //h4[contains(text(),"Copy Target Project To")]
    # Wait For Elements State    //legend[contains(text(),"Search Criteria")]
    # Get Text    ${Project_CopyData_Mode}/option[@selected="selected"]    ==    AIR
    # Get Attribute    ${Project_CopyData_Customer Name}    placeholder    ==    ${EMPTY}
    # Get Attribute    ${Project_CopyData_TenderID}    placeholder    ==    ALL
    # Get Attribute    ${Project_CopyData_TenderLead}    placeholder    ==    ALL
    # Get Attribute    ${Project_CopyData_RFQLaunchDate}    placeholder    ==    DD/MM/YYYY
    # Wait For Elements State    ${Project_CopyData_SearchButton}
    # Wait For Elements State    ${Project_CopyData_CopyDataButton}
    # Get Attribute    ${Project_CopyData_CopyDataButton}    disabled    ==    disabled
    # Wait For Elements State    ${Project_CopyData_Noentrypresent}
    Copy Data    2024000001    AIR    do not touch me

Step ${step} Input Tender ID With Value 2024000001 Click On Search
    #************************Step 6******************************
    #  Do:
    #      Input Tender ID with value 2024000001 click on Search
    #     button
    #  Expected:
    #      index php attachments get bbed6818 f35c 4750 983e
    #     8bad0a53a928 Result list has one entry as above
    #     information
    #************************************************************
    # Fill Text    ${Project_CopyData_TenderID}    2024000001
    # Click    ${Project_CopyData_SearchButton}
    Log    finish in last step
   

Step ${step} Select This Entry Click On Copy Data Button And Yes In
    #************************Step 7******************************
    #  Do:
    #      Select this entry click on Copy Data button and Yes in
    #     pop up window
    #  Expected:
    #      Successfully with messages in pop up window
    #      Tender has been successfully copied from 2024000001 AIR
    #     do not touch me
    #      Please adjust the template and the lanes in Template
    #     Lane Management page if required
    #      After click on OK button
    #      The same message is displayed in Pricing Project page
    #     too
    #************************************************************
    # Wait For Elements State    //td[.="do not touch me"]
    # Click    //td[.="do not touch me"]
    # Click    ${Project_CopyData_CopyDataButton}
    # Click    ${Dialog_yesButton}
    # Wait For Elements State    //span[contains(text(),"Tender has been successfully copied from [2024000001-AIR-do not touch me].")]
    # Wait For Elements State    //span[contains(text(),"Please adjust the template and the lanes in Template / Lane Management page if required.")]
    # Click    //button[span[.="OK"]]
    # Wait For Elements State    //span[contains(text(),"Tender has been successfully copied from [2024000001-AIR-do not touch me]. Please adjust the template and the lanes in Template / Lane Management page if required.")]
    Log    finish in last step

Step ${step} Select Current Project In Pricing Project Click On
    #************************Step 8******************************
    #  Do:
    #      Select current project in pricing project click on
    #     template management button
    #  Expected:
    #      In the dialog check the information under Step2 should
    #     be the same as project 2024000001 AIR do not touch me
    #************************************************************
    Click    //td[contains(text(),"${G_TENDERID}")]
    Click    ${Project_toolbar_TemplateManagementButton}
    #it has too many fields in dialog and did not check specific fields information for 2024000001 in privous step

Step ${step} Click Skip Button In Step4 and Yes In The Pop up
    #************************Step 9******************************
    #  Do:
    #      Click Skip button in Step4 and Yes in the pop up
    #     windown
    #  Expected:
    #      Next Round Management button is enable
    #************************************************************
    Click    //button[.="Skip"]
    Wait For Elements State    //span[contains(text(),"Are you sure to skip push pricing?")]
    Click    ${Dialog_yesButton}
    Sleep    2
    Wait For Elements State    //button[contains(text(),"Next: Round Management")]    enabled

Step ${step} User Clicks Next Round Management Button
    #************************Step 10******************************
    #  Do:
    #      User clicks Next round management button
    #  Expected:
    #      A dialogue named Project 20240815 AIR Regression Round1
    #     display
    #      It divides into 5 parts
    #      1 Generation Information current Pricing Round 1
    #     Started 2 lanes
    #      2 Assignment
    #      3 Attached Document
    #      4 Round History
    #      5 The tasks status Region Country My tasks
    #************************************************************
    Click    //button[contains(text(),"Next: Round Management")]
    Wait For Elements State    //h4/span[contains(text(),"Project ${G_TENDERID}-AIR-${TenderTitle}")]
    Wait For Elements State    //legend[.="Generation Information"]
    Wait For Elements State    //legend[.="Assignment"]
    Wait For Elements State    //legend[.="Attached Document"]
    Wait For Elements State    //legend[.="Round History"]
    Wait For Elements State    //a[.="Region"]
    Wait For Elements State    //a[.="My Tasks"]

Step ${step} User Clicks Update Lane Button
    #************************Step 11******************************
    #  Do:
    #      User clicks update lane button
    #  Expected:
    #     1. A dialog with the name of project name is displayed".
    #     2. There are three check boxes: update existing lanes, delete existing lanes and add new lanes.
    #     3. There are two boxes:next and close.
    #************************************************************
    Click    ${Project_RoundMgmt_UpdateLaneButton}

    Wait For Elements State    //legend[.="I want to:"]/following-sibling::div//input[@value="update"]
    Get Text    //legend[.="I want to:"]/following-sibling::div//input[@value="update"]/..    contains    Update Existing Lanes
    Wait For Elements State    //legend[.="I want to:"]/following-sibling::div//input[@value="delete"]
    Get Text    //legend[.="I want to:"]/following-sibling::div//input[@value="delete"]/..    contains    Delete Existing Lanes
    Wait For Elements State    //legend[.="I want to:"]/following-sibling::div//input[@value="create"]
    Get Text    //legend[.="I want to:"]/following-sibling::div//input[@value="create"]/..    contains    Add New Lanes
    Wait For Elements State    //button[.="Next"]
    Wait For Elements State    //button[.="Next"]/following-sibling::button

Step ${step} Select Update Existing Lanes
    #************************Step 12******************************
    #  Do:
    #      Select Update Existing Lanes, click on Next button.
    #  Expected:
    #     1. A new dialog with the name of project name is displayed.
    #     2. Download, Upload, Back, Close buttons are displayed.
    #************************************************************
    Click    //button[.="Next"]

    Wait For Elements State    ${Project_UpdateLane_DownloadButton}
    Wait For Elements State    ${Project_UpdateLane_UploadButton}
    Wait For Elements State    ${Project_UpdateLane_CloseButton}
    Wait For Elements State    //button[.="Back"]

Step ${step} User Clicks Download Button
    #************************Step 12******************************
    #  Do:
    #      User clicks download button
    #  Expected:
    #      A file downloads successfully
    #************************************************************
    ${filename}    Download File    ${Project_UpdateLane_DownloadButton}
    Set Test Variable    ${filename}    ${filename}
    Wait Until Search Finished


Step ${step} User Opens The Downloaded File
    #************************Step 13******************************
    #  Do:
    #      User opens the downloaded file
    #  Expected:
    #      The download file has all of the pricing information It
    #     has two lanes
    #************************************************************
    Open Excel Document     ${filename}    ${PROJECT.MODE}
    ${landInfo}    Read Excel Column    1
    ${rowCount}    Get Length    ${landInfo}
    Should Be Equal As Integers    ${rowCount}    6

Step ${step} User Modifies Some Pricing Data From The Download File
    #************************Step 14******************************
    #  Do:
    #      User modifies some pricing data from the download file
    #     and upload this file as
    #      index php attachments get 578766ac 0527 40c8 8299
    #     3c65c2f1cdcc
    #  Expected:
    #      A prompt Upload Result appears on the top
    #      Upload Failed
    #      Error in excel row 5
    #      Temperature range is not provided Please check and
    #     revise BQ
    #************************************************************
    Write Excel Cell    5    68    Y    ${PROJECT.MODE}_D
    Write Excel Cell    6    68    N    ${PROJECT.MODE}_D
    Write Excel Cell    6    69    ${111}    ${PROJECT.MODE}_D
    Write Excel Cell    6    70    ${111}    ${PROJECT.MODE}_D
    Write Excel Cell    6    71    ${111}    ${PROJECT.MODE}_D
    
    Save Excel Document    ${filename}
    Close Current Excel Document
    Reopen And Save Excel    ${filename}
    
    Wait Until Keyword Succeeds   100    1    Click    ${Project_UpdateLane_UploadButton}
    Wait For Elements State   ${upload_addFileButton}     enabled
    Sleep    2
    Upload File By Selector    ${upload_addFileButton}    ${filename}
    Wait Until Search Finished
    Wait For Elements State    //h4[.="Error in excel row 5"]
    Wait For Elements State    //li[.="Temperature range is not provided. Please check and revise! [ BQ ]"]
    Click    //button[span[.="OK"]]

Step ${step} User Modifies Some Pricing Data From The Download File 15
    #************************Step 15******************************
    #  Do:
    #      User modifies some pricing data from the download file
    #     and upload this file as index php attachments get
    #     10b71f03 2752 4b0c 9a28 d659ee8f7390
    #  Expected:
    #      A prompt Upload Result appears on the top
    #      Upload Failed
    #      Error in excel row 5
    #      abc must be in decimal format Please check and revise
    #     CH CI CJ CK CL CM CN
    #************************************************************
    ${filename}    Download File    ${Project_UpdateLane_DownloadButton}
    Set Test Variable    ${filename}    ${filename}
    Wait Until Search Finished
    Open Excel Document     ${filename}    ${PROJECT.MODE}
    Write Excel Cell    5    86    abc    ${PROJECT.MODE}_D
    Write Excel Cell    5    87    abc    ${PROJECT.MODE}_D
    Write Excel Cell    5    88    abc    ${PROJECT.MODE}_D
    Write Excel Cell    5    89    abc    ${PROJECT.MODE}_D
    Write Excel Cell    5    90    abc    ${PROJECT.MODE}_D
    Write Excel Cell    5    91    abc    ${PROJECT.MODE}_D
    Write Excel Cell    5    92    abc    ${PROJECT.MODE}_D
    Save Excel Document    ${filename}
    Close Current Excel Document
    Reopen And Save Excel    ${filename}
    Wait Until Keyword Succeeds   100    1    Click    ${Project_UpdateLane_UploadButton}
    Wait For Elements State   ${upload_addFileButton}     enabled
    Sleep    2
    Upload File By Selector    ${upload_addFileButton}    ${filename}
    Wait Until Search Finished
    Wait For Elements State    //h4[.="Error in excel row 5"]
    Wait For Elements State    //li[.="abc must be in decimal format. Please check and revise! [ CH,CI,CJ,CK,CL,CM,CN ]"]
    Click    //button[span[.="OK"]]

Step ${step} User Modifies Some Pricing Data From The Download File 16
    #************************Step 16******************************
    #  Do:
    #      User modifies some pricing data from the download file
    #     and upload this file as index php attachments get
    #     23dab8d4 b202 4faa a590 e62030c1dc6f
    #  Expected:
    #      A prompt Upload Result appears on the top
    #      Error in excel row 5
    #      Unknown currency code Please check and revise DL
    #      1231231123 1233301 must be in decimal format Please
    #     check and revise DO DP DQ DR DS DT DU DV DW DX DY DZ EA
    #     EB
    #************************************************************
    ${filename}    Download File    ${Project_UpdateLane_DownloadButton}
    Set Test Variable    ${filename}    ${filename}
    Wait Until Search Finished
    Open Excel Document     ${filename}    ${PROJECT.MODE}
    Write Excel Cell    5    116    abc    ${PROJECT.MODE}_D
    Write Excel Cell    5    117    ${100.00}    ${PROJECT.MODE}_D
    Write Excel Cell    5    118    ${100.00}    ${PROJECT.MODE}_D
    Write Excel Cell    5    119    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    120    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    121    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    122    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    123    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    124    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    125    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    126    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    127    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    128    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    129    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    130    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    131    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Write Excel Cell    5    132    ${1231231123.1233301}    ${PROJECT.MODE}_D
    Save Excel Document    ${filename}
    Close Current Excel Document
    Reopen And Save Excel    ${filename}
    Wait Until Keyword Succeeds   100    1    Click    ${Project_UpdateLane_UploadButton}
    Wait For Elements State   ${upload_addFileButton}     enabled
    Sleep    2
    Upload File By Selector    ${upload_addFileButton}    ${filename}
    Wait Until Search Finished
    Wait For Elements State    //h4[.="Error in excel row 5"]
    Wait For Elements State    //li[.="Unknown currency code. Please check and revise! [ DL ]"]
    Wait For Elements State    //li[.="1231231123.1233301 must be in decimal format. Please check and revise! [ DO,DP,DQ,DR,DS,DT,DU,DV,DW,DX,DY,DZ,EA,EB ]"]
    Click    //button[span[.="OK"]]

Step ${step} User Modifies Some Pricing Data From The Download File 17
    #************************Step 17******************************
    #  Do:
    #      User modifies some pricing data from the download file
    #     and upload this file as index php attachments get
    #     51f4e4cb b95a 4e44 abea 06cb445a418f
    #  Expected:
    #      A prompt Upload Result appears on the top
    #      Upload Failed
    #      Error in excel row 5
    #      Unknown currency code Please check and revise FV FP FS
    #      Input value exceeds the constraint max length of this
    #     is 256 characters Please check and revise FW FX FN FQ FT
    #      1231231231 1229999 must be in decimal format Please
    #     check and revise FO FR FU
    #************************************************************
    ${filename}    Download File    ${Project_UpdateLane_DownloadButton}
    Set Test Variable    ${filename}    ${filename}
    Wait Until Search Finished
    Open Excel Document     ${filename}    ${PROJECT.MODE}
    ${long_val}    Evaluate    'a'*257
    
    Write Excel Cell    5    170    ${long_val}    ${PROJECT.MODE}_D
    Write Excel Cell    5    173    ${long_val}    ${PROJECT.MODE}_D
    Write Excel Cell    5    176    ${long_val}    ${PROJECT.MODE}_D
    Write Excel Cell    5    179    ${long_val}    ${PROJECT.MODE}_D
    Write Excel Cell    5    180    ${long_val}    ${PROJECT.MODE}_D

    Write Excel Cell    5    171    ${1231231231.1229999}    ${PROJECT.MODE}_D
    Write Excel Cell    5    174    ${1231231231.1229999}    ${PROJECT.MODE}_D
    Write Excel Cell    5    177    ${1231231231.1229999}    ${PROJECT.MODE}_D

    Write Excel Cell    5    172    abc    ${PROJECT.MODE}_D
    Write Excel Cell    5    175    abc    ${PROJECT.MODE}_D
    Write Excel Cell    5    178    abc    ${PROJECT.MODE}_D

    Save Excel Document    ${filename}
    Close Current Excel Document
    Reopen And Save Excel    ${filename}
    Wait Until Keyword Succeeds   100    1    Click    ${Project_UpdateLane_UploadButton}
    Wait For Elements State   ${upload_addFileButton}     enabled
    Sleep    2
    Upload File By Selector    ${upload_addFileButton}    ${filename}
    Wait Until Search Finished
    Wait For Elements State    //h4[.="Error in excel row 5"]
    Wait For Elements State    //li[.="Unknown currency code. Please check and revise! [ FV,FP,FS ]"]
    Wait For Elements State    //li[.="Input value exceeds the constraint, max length of this is 256 characters. Please check and revise! [ FW,FX,FN,FQ,FT ]"]
    Wait For Elements State    //li[.="1231231231.1229999 must be in decimal format. Please check and revise! [ FO,FR,FU ]"]
    Click    //button[span[.="OK"]]

Step ${step} User Modifies Some Pricing Data From The Download File 18
    #************************Step 18******************************
    #  Do:
    #      User modifies some pricing data from the download file
    #     and upload this file as index php attachments get
    #     2916b7d6 5424 4a9b b8fa 23ee2420337c
    #  Expected:
    #      Successfully uploaded
    #************************************************************
    ${filename}    Download File    ${Project_UpdateLane_DownloadButton}
    Set Test Variable    ${filename}    ${filename}
    Wait Until Search Finished
    Open Excel Document     ${filename}    ${PROJECT.MODE}

    Write Excel Cell    5    216    updated    ${PROJECT.MODE}_D
    Write Excel Cell    5    217    updated    ${PROJECT.MODE}_D
    Write Excel Cell    5    218    updated    ${PROJECT.MODE}_D
    Write Excel Cell    5    219    updated    ${PROJECT.MODE}_D
    Write Excel Cell    5    220    updated    ${PROJECT.MODE}_D
    Write Excel Cell    5    221    updated    ${PROJECT.MODE}_D
    Write Excel Cell    5    222    updated    ${PROJECT.MODE}_D

    Write Excel Cell    6    216    updated    ${PROJECT.MODE}_D
    Write Excel Cell    6    217    updated    ${PROJECT.MODE}_D
    Write Excel Cell    6    218    updated    ${PROJECT.MODE}_D
    Write Excel Cell    6    219    updated    ${PROJECT.MODE}_D
    Write Excel Cell    6    220    updated    ${PROJECT.MODE}_D
    Write Excel Cell    6    221    updated    ${PROJECT.MODE}_D
    Write Excel Cell    6    222    updated    ${PROJECT.MODE}_D

    Save Excel Document    ${filename}
    Close Current Excel Document
    Reopen And Save Excel    ${filename}
    Wait Until Keyword Succeeds   100    1    Click    ${Project_UpdateLane_UploadButton}
    Wait For Elements State   ${upload_addFileButton}     enabled
    Sleep    2
    Upload File By Selector    ${upload_addFileButton}    ${filename}
    Wait Until Search Finished
    Wait For Elements State    //span[.="Successfully uploaded"]
    
Step ${step} Click On Download Button Check The Downloaded File
    #************************Step 19******************************
    #  Do:
    #      Click on Download button check the downloaded file
    #  Expected:
    #      File download successfully and check the modified place
    #     are the same with the download file
    #************************************************************
    ${filename}    Download File    ${Project_UpdateLane_DownloadButton}
    Set Test Variable    ${filename}    ${filename}
    Wait Until Search Finished
    Open Excel Document     ${filename}    ${PROJECT.MODE}

    ${UPDATE}    Read Excel Cell    5    216    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    5    217    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    5    218    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    5    219    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    5    220    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    5    221    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    5    222    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated

    ${UPDATE}    Read Excel Cell    6    216    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    6    217    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    6    218    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    6    219    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    6    220    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    6    221    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    ${UPDATE}    Read Excel Cell    6    222    ${PROJECT.MODE}_D
    Should Be Equal    ${UPDATE}     updated
    Close Current Excel Document

Step ${step} In Pricing Project Page User Selects TenderID Contains
    #************************Step 20******************************
    #  Do:
    #      In Pricing Project page User selects TenderID Contains
    #     20240815
    #  Expected:
    #      The project could be found
    #************************************************************
    Click   ${Project_UpdateLane_CloseButton}
    Wait Until Search Finished
    Click    //button[.="Close"]
    Wait For Elements State    //td[contains(text(),"${G_TENDERID}")]
    

Step ${step} Select This Project 20240815 AIR Regression Click On
    #************************Step 21******************************
    #  Do:
    #      Select this project 20240815 AIR Regression click on
    #     Delete Project button
    #      Click Yes of the pop up confirm window
    #  Expected:
    #      System displays Project has been deleted
    #************************************************************
    Delete Project    ${G_TENDERID}

Step ${step} User Goes To Basic Data Management Tender List 22
    #************************Step 22******************************
    #  Do:
    #      User goes to Basic Data Management Tender List
    #      Search out the tender created in step1
    #      Click on Delete button
    #      Click on Yes button in the popup dialog
    #  Expected:
    #      System displays Tender has been deleted
    #************************************************************
    Delete Tender    ${G_TENDERID}
